# Description:
#   Brute force KNN/ENN search.

package(
    default_visibility = ["//visibility:public"],
    licenses = ["notice"],
)

cc_library(
    name = "brute_force",
    srcs = [
        "brute_force.cc",
        "brute_force_mutator.cc",
    ],
    hdrs = ["brute_force.h"],
    tags = ["local"],
    deps = [
        "//scann/base:restrict_allowlist",
        "//scann/base:search_parameters",
        "//scann/base:single_machine_base",
        "//scann/data_format:datapoint",
        "//scann/data_format:dataset",
        "//scann/distance_measures",
        "//scann/distance_measures/many_to_many",
        "//scann/distance_measures/one_to_many",
        "//scann/oss_wrappers:scann_aligned_malloc",
        "//scann/oss_wrappers:scann_down_cast",
        "//scann/oss_wrappers:tf_dependency",
        "//scann/utils:common",
        "//scann/utils:fast_top_neighbors",
        "//scann/utils:single_machine_autopilot",
        "//scann/utils:top_n_amortized_constant",
        "//scann/utils:types",
        "//scann/utils/intrinsics:sse4",
        "@com_google_absl//absl/base",
        "@com_google_absl//absl/flags:flag",
        "@com_google_absl//absl/log",
        "@com_google_absl//absl/synchronization",
    ],
)

cc_library(
    name = "scalar_quantized_brute_force",
    srcs = [
        "scalar_quantized_brute_force.cc",
        "scalar_quantized_brute_force_mutator.cc",
    ],
    hdrs = ["scalar_quantized_brute_force.h"],
    tags = ["local"],
    deps = [
        "//scann/base:search_parameters",
        "//scann/base:single_machine_base",
        "//scann/base:single_machine_factory_options",
        "//scann/data_format:datapoint",
        "//scann/data_format:dataset",
        "//scann/distance_measures",
        "//scann/distance_measures/one_to_many",
        "//scann/distance_measures/one_to_one:dot_product",
        "//scann/distance_measures/one_to_one:l2_distance",
        "//scann/oss_wrappers:scann_status",
        "//scann/tree_x_hybrid:leaf_searcher_optional_parameter_creator",
        "//scann/utils:common",
        "//scann/utils:datapoint_utils",
        "//scann/utils:fast_top_neighbors",
        "//scann/utils:scalar_quantization_helpers",
        "//scann/utils:types",
        "//scann/utils/fixed_point:pre_quantized_fixed_point",
        "@com_google_absl//absl/log",
        "@com_google_absl//absl/log:check",
        "@com_google_absl//absl/strings",
        "@com_google_absl//absl/strings:str_format",
    ],
)

cc_library(
    name = "bfloat16_brute_force",
    srcs = [
        "bfloat16_brute_force.cc",
        "bfloat16_brute_force_mutator.cc",
    ],
    hdrs = ["bfloat16_brute_force.h"],
    tags = ["local"],
    deps = [
        "//scann/base:single_machine_base",
        "//scann/data_format:datapoint",
        "//scann/distance_measures",
        "//scann/distance_measures/one_to_many",
        "//scann/oss_wrappers:scann_status",
        "//scann/utils:bfloat16_helpers",
        "//scann/utils:common",
        "//scann/utils:fast_top_neighbors",
        "//scann/utils:types",
        "@com_google_absl//absl/strings",
    ],
)
